package com.indusfo.spc.mapper;

import com.indusfo.spc.pojo.BadphenoType;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * @ProjectName: IEIS2-COM
 * @Package: com.indusfo.spc.mapper
 * @ClassName: BadphenoTypeMapper
 * @Author: 熊冰
 * @Description: 不良现象类型 数据层
 * @Date: 2019/8/20 9:57
 * @Version: 1.0
 */
public interface BadphenoTypeMapper {
    //新增
    int insertSelective(BadphenoType badphenoType);
    //修改
    int updateByPrimaryKeySelective(BadphenoType badphenoType);
    //删除
    int deleteBadphenoType(@Param("ids") Long[] ids, @Param("dataState") Integer dataState);
    //全查
    List<BadphenoType> selectAllBadphenoType(BadphenoType badphenoType);
    //总数
    int countBadphenoType(BadphenoType badphenoType);
    //验证是否重复
    int countParamsNotRepeat(BadphenoType badphenoType);
    //通过父编码判断是否存在子类
    int countByBadphenoTypePid(@Param("badphenoTypePids") Long[] badphenoTypePids);

    List<BadphenoType> selectAllBadphenoTypeToInsert(BadphenoType badphenoType);
}
